package com.sudichina.sudichina.view.fragment;

import com.sudichina.sudichina.bean.CarOrder;

import java.util.ArrayList;
import java.util.List;

/**
 * Name: AllFragment
 * Action:
 * Author: liuan
 * creatTime:2017-03-08 13:17
 */

public class HearFragment  extends BaseFragemnt {
    @Override
    public CharSequence getTitle() {
        return "审理中";
    }




    @Override
    protected List<CarOrder.ContentBean> setListData(List<CarOrder.ContentBean> content) {



        List<CarOrder.ContentBean> finishOlders= new ArrayList<>();


/**
 * 遍历集合  找出其中的完成的订单
 */
        for (CarOrder.ContentBean contentBean :
                content) {

            String tradeStatus = contentBean.getTradeStatus();

            // TODO: 2017/3/22 审理中的状态 是??????
            if (tradeStatus.contains("Dai")){
                //添加到新的集合中
                finishOlders.add (contentBean);
            }


        }





        return finishOlders;
    }


}

